how to program a motor reverse and forward control